package com.tanhua.model.vo;

import com.tanhua.model.domain.Options;
import com.tanhua.model.domain.UserInfo;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * 题目的选项Vo
 *
 * @author 李磊
 * @since 2022-01-14 9:35
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class OptionsVo implements Serializable {
    /**
     * 选项id
     */
    private  String id;
    /**
     * 选项内容
     */
    private String option;

    public static OptionsVo init(Options options) {

        OptionsVo vo = new OptionsVo();

        vo.setId(options.getId().toString());
        vo.setOption(options.getOption());
        return vo;
    }
}
